package com.fzf.org.anno;


import com.fzf.org.anno.validator.MyPhoneValidator;
import jakarta.validation.Constraint;
import jakarta.validation.Payload;

import java.lang.annotation.*;

@Documented
@Target({ElementType.FIELD, ElementType.ANNOTATION_TYPE, ElementType.PARAMETER})
@Retention(RetentionPolicy.RUNTIME)
@Constraint(
        validatedBy = {MyPhoneValidator.class}
)
public @interface MyPhone {

    String message() default "手机号必须严格符合中国规定";

    Class<?>[] groups() default {};

    Class<? extends Payload>[] payload() default {};

}
